package com.neusoft.yiyang.medical.client;

import com.neusoft.yiyang.common.entity.customer.Customer;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient(name = "customer-service")
public interface CustomerClient {

    @PostMapping("/customers/{customerId}/diet-tag")
    void assignDietTag(@PathVariable Integer customerId, @RequestParam Integer dietTagId);

    @DeleteMapping("/customers/{customerId}/diet-tag")
    void removeDietTag(@PathVariable Integer customerId);

    @GetMapping("/customers/{customerId}/diet-tag")
    Integer getDietTag(@PathVariable Integer customerId);

    // 根据ID获取客户信息
    @GetMapping("/customers/{customerId}")
    Customer getCustomerById(@PathVariable("customerId") Integer customerId);
}